package org.ehe.finance.subject.domain.bo;

import org.ehe.common.mybatis.core.domain.BaseEntity2;
import io.github.linpeilie.annotations.AutoMapper;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.ehe.common.core.validate.AddGroup;
import org.ehe.common.core.validate.EditGroup;
import org.ehe.finance.subject.domain.ErpFinanceAccountSubject;

/**
 * @author :zhangnn
 * @className :ErpFinanceAccountSubjectBo
 * @description: TODO
 * @date 2025-08-22 09:42:29
 */
@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = ErpFinanceAccountSubject.class, reverseConvertGenerate = false)
public class ErpFinanceAccountSubjectBo extends BaseEntity2 {
    /**
     * 科目编号
     */
    @NotNull(message = "科目编号不能为空", groups = {EditGroup.class})
    private Long id;

    /**
     * 科目名称
     */
    @NotBlank(message = "科目名称不能为空", groups = {AddGroup.class, EditGroup.class})
    private String subjectName;

    /**
     * 科目编码
     */
//    @NotBlank(message = "科目编码不能为空", groups = {AddGroup.class, EditGroup.class})
    private String subjectCode;

    /**
     * 父级科目编号
     */
    @NotNull(message = "父级科目编号不能为空", groups = {AddGroup.class, EditGroup.class})
    private Long parentId;

    /**
     * 科目级别
     */
    //@NotNull(message = "科目级别不能为空", groups = {AddGroup.class, EditGroup.class})
    private Integer subjectLevel;

    /**
     * 科目类型（1-资产类 2-负债类 3-共同类 4-所有者权益类 5-成本类 6-损益类）
     */
    @NotNull(message = "科目类型不能为空", groups = {AddGroup.class, EditGroup.class})
    private Integer subjectType;

    /**
     * 余额方向（1-借方 2-贷方）
     */
    @NotNull(message = "余额方向不能为空", groups = {AddGroup.class, EditGroup.class})
    private Integer balanceDirection;

    /**
     * 科目状态（0-禁用 1-启用）
     */
    @NotNull(message = "科目状态不能为空", groups = {AddGroup.class, EditGroup.class})
    private Integer status;

    /**
     * 科目备注
     */
    private String remark;

}
